#include <iostream>
using namespace std;

class Cat {
public:
	Cat() {
		itsAge = new int;
		*itsAge = 5;
	}

	Cat(Cat &cat) {
		this->itsAge = new int(cat.getAge());
	}

	~Cat() {
		delete itsAge;
	}

	int getAge() {
		return *this->itsAge;
	}

	void setAge(int a) {
		*this->itsAge = a;
	}

private:
	int *itsAge;
};


//int main() {
//	Cat c1;
//	Cat c2(c1);
//	c2.setAge(6);
//	cout << c1.getAge() << endl;
//	return 0;
//}